﻿//Created by Action Script Viewer - http://www.buraks.com/asv
package Modules.guide.actions {
    import Engine.Classes.*;
    import Engine.Managers.*;
    import Modules.guide.*;

    public class GuideAction extends State {

        protected var m_guide:Guide;
        protected var m_seq:GuideSequence;

        public function setGuide(_arg1:Guide, _arg2:GuideSequence):void{
            this.m_guide = _arg1;
            this.m_seq = _arg2;
        }
        public function createFromXml(_arg1:XML):Boolean{
            return (false);
        }
        protected function removeState(_arg1:GuideAction):void{
            if (this.m_seq){
                this.m_seq.getActionExec().removeState(_arg1);
            };
        }
        protected function checkAndGetElement(_arg1:XML, _arg2:String):XMLList{
            if (_arg1.hasOwnProperty(_arg2)){
                return (_arg1.elements(_arg2));
            };
            ErrorManager.addError((("XML element named '" + _arg2) + "' not found in tutorial definition!"));
            return (null);
        }
        override public function enter():void{
            this.m_guide.displayLoadingMask();
        }
        override public function update(_arg1:Number):void{
            if (((this.allAssetsLoaded()) && (this.m_guide))){
                this.m_guide.removeLoadingMask();
            };
        }
        protected function allAssetsLoaded():Boolean{
            return (true);
        }

    }
}//package Modules.guide.actions 
